dy-lib=libmymethod.so

.PHONY:all
all: $(dy-lib)

$(dy-lib):mylog.o myprint.o
	gcc -shared -o $@ $^

mylog.o:mylog.c
	gcc -fPIC -c $^
myprint.o:myprint.c
	gcc -fPIC -c $^

.PHONY:clean
clean:
	rm -rf *.o *.so dy-lib

.PHONY:output
output:
	mkdir -p dy-lib/include
	mkdir -p dy-lib/my-dy-lib
	cp *.h dy-lib/include
	cp *.so dy-lib/my-dy-lib

